Integrand size = 25, antiderivative size = 356 \[ \int \frac {x^3 (a+b \arctan (c x))^2}{d+i c d x} \, dx=-\frac {a b x}{c^3 d}-\frac {i b^2 x}{3 c^3 d}+\frac {i b^2 \arctan (c x)}{3 c^4 d}-\frac {b^2 x \arctan (c x)}{c^3 d}+\frac {i b x^2 (a+b \arctan (c x))}{3 c^2 d}-\frac {5 (a+b \arctan (c x))^2}{6 c^4 d}+\frac {i x (a+b \arctan (c x))^2}{c^3 d}+\frac {x^2 (a+b \arctan (c x))^2}{2 c^2 d}-\frac {i x^3 (a+b \arctan (c x))^2}{3 c d}+\frac {8 i b (a+b \arctan (c x)) \log \left (\frac {2}{1+i c x}\right )}{3 c^4 d}+\frac {(a+b \arctan (c x))^2 \log \left (\frac {2}{1+i c x}\right )}{c^4 d}+\frac {b^2 \log \left (1+c^2 x^2\right )}{2 c^4 d}-\frac {4 b^2 \operatorname {PolyLog}\left (2,1-\frac {2}{1+i c x}\right )}{3 c^4 d}+\frac {i b (a+b \arctan (c x)) \operatorname {PolyLog}\left (2,1-\frac {2}{1+i c x}\right )}{c^4 d}+\frac {b^2 \operatorname {PolyLog}\left (3,1-\frac {2}{1+i c x}\right )}{2 c^4 d} \]
[Out]
Time = 0.63 (sec) , antiderivative size = 356, normalized size of antiderivative = 1.00, number of steps used = 26, number of rules used = 14, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.560, Rules used = {4986, 4946, 5036, 327, 209, 5040, 4964, 2449, 2352, 4930, 266, 5004, 5114, 6745} \[ \int \frac {x^3 (a+b \arctan (c x))^2}{d+i c d x} \, dx=\frac {i b \operatorname {PolyLog}\left (2,1-\frac {2}{i c x+1}\right ) (a+b \arctan (c x))}{c^4 d}-\frac {5 (a+b \arctan (c x))^2}{6 c^4 d}+\frac {\log \left (\frac {2}{1+i c x}\right ) (a+b \arctan (c x))^2}{c^4 d}+\frac {8 i b \log \left (\frac {2}{1+i c x}\right ) (a+b \arctan (c x))}{3 c^4 d}+\frac {i x (a+b \arctan (c x))^2}{c^3 d}+\frac {x^2 (a+b \arctan (c x))^2}{2 c^2 d}+\frac {i b x^2 (a+b \arctan (c x))}{3 c^2 d}-\frac {i x^3 (a+b \arctan (c x))^2}{3 c d}-\frac {a b x}{c^3 d}+\frac {i b^2 \arctan (c x)}{3 c^4 d}-\frac {b^2 x \arctan (c x)}{c^3 d}-\frac {4 b^2 \operatorname {PolyLog}\left (2,1-\frac {2}{i c x+1}\right )}{3 c^4 d}+\frac {b^2 \operatorname {PolyLog}\left (3,1-\frac {2}{i c x+1}\right )}{2 c^4 d}-\frac {i b^2 x}{3 c^3 d}+\frac {b^2 \log \left (c^2 x^2+1\right )}{2 c^4 d} \]
[In]
[Out]
Rule 209
Rule 266
Rule 327
Rule 2352
Rule 2449
Rule 4930
Rule 4946
Rule 4964
Rule 4986
Rule 5004
Rule 5036
Rule 5040
Rule 5114
Rule 6745
Rubi steps \begin{align*} \text {integral}& = \frac {i \int \frac {x^2 (a+b \arctan (c x))^2}{d+i c d x} \, dx}{c}-\frac {i \int x^2 (a+b \arctan (c x))^2 \, dx}{c d} \\ & = -\frac {i x^3 (a+b \arctan (c x))^2}{3 c d}-\frac {\int \frac {x (a+b \arctan (c x))^2}{d+i c d x} \, dx}{c^2}+\frac {(2 i b) \int \frac {x^3 (a+b \arctan (c x))}{1+c^2 x^2} \, dx}{3 d}+\frac {\int x (a+b \arctan (c x))^2 \, dx}{c^2 d} \\ & = \frac {x^2 (a+b \arctan (c x))^2}{2 c^2 d}-\frac {i x^3 (a+b \arctan (c x))^2}{3 c d}-\frac {i \int \frac {(a+b \arctan (c x))^2}{d+i c d x} \, dx}{c^3}+\frac {i \int (a+b \arctan (c x))^2 \, dx}{c^3 d}+\frac {(2 i b) \int x (a+b \arctan (c x)) \, dx}{3 c^2 d}-\frac {(2 i b) \int \frac {x (a+b \arctan (c x))}{1+c^2 x^2} \, dx}{3 c^2 d}-\frac {b \int \frac {x^2 (a+b \arctan (c x))}{1+c^2 x^2} \, dx}{c d} \\ & = \frac {i b x^2 (a+b \arctan (c x))}{3 c^2 d}-\frac {(a+b \arctan (c x))^2}{3 c^4 d}+\frac {i x (a+b \arctan (c x))^2}{c^3 d}+\frac {x^2 (a+b \arctan (c x))^2}{2 c^2 d}-\frac {i x^3 (a+b \arctan (c x))^2}{3 c d}+\frac {(a+b \arctan (c x))^2 \log \left (\frac {2}{1+i c x}\right )}{c^4 d}+\frac {(2 i b) \int \frac {a+b \arctan (c x)}{i-c x} \, dx}{3 c^3 d}-\frac {b \int (a+b \arctan (c x)) \, dx}{c^3 d}+\frac {b \int \frac {a+b \arctan (c x)}{1+c^2 x^2} \, dx}{c^3 d}-\frac {(2 b) \int \frac {(a+b \arctan (c x)) \log \left (\frac {2}{1+i c x}\right )}{1+c^2 x^2} \, dx}{c^3 d}-\frac {(2 i b) \int \frac {x (a+b \arctan (c x))}{1+c^2 x^2} \, dx}{c^2 d}-\frac {\left (i b^2\right ) \int \frac {x^2}{1+c^2 x^2} \, dx}{3 c d} \\ & = -\frac {a b x}{c^3 d}-\frac {i b^2 x}{3 c^3 d}+\frac {i b x^2 (a+b \arctan (c x))}{3 c^2 d}-\frac {5 (a+b \arctan (c x))^2}{6 c^4 d}+\frac {i x (a+b \arctan (c x))^2}{c^3 d}+\frac {x^2 (a+b \arctan (c x))^2}{2 c^2 d}-\frac {i x^3 (a+b \arctan (c x))^2}{3 c d}+\frac {2 i b (a+b \arctan (c x)) \log \left (\frac {2}{1+i c x}\right )}{3 c^4 d}+\frac {(a+b \arctan (c x))^2 \log \left (\frac {2}{1+i c x}\right )}{c^4 d}+\frac {i b (a+b \arctan (c x)) \operatorname {PolyLog}\left (2,1-\frac {2}{1+i c x}\right )}{c^4 d}+\frac {(2 i b) \int \frac {a+b \arctan (c x)}{i-c x} \, dx}{c^3 d}+\frac {\left (i b^2\right ) \int \frac {1}{1+c^2 x^2} \, dx}{3 c^3 d}-\frac {\left (2 i b^2\right ) \int \frac {\log \left (\frac {2}{1+i c x}\right )}{1+c^2 x^2} \, dx}{3 c^3 d}-\frac {\left (i b^2\right ) \int \frac {\operatorname {PolyLog}\left (2,1-\frac {2}{1+i c x}\right )}{1+c^2 x^2} \, dx}{c^3 d}-\frac {b^2 \int \arctan (c x) \, dx}{c^3 d} \\ & = -\frac {a b x}{c^3 d}-\frac {i b^2 x}{3 c^3 d}+\frac {i b^2 \arctan (c x)}{3 c^4 d}-\frac {b^2 x \arctan (c x)}{c^3 d}+\frac {i b x^2 (a+b \arctan (c x))}{3 c^2 d}-\frac {5 (a+b \arctan (c x))^2}{6 c^4 d}+\frac {i x (a+b \arctan (c x))^2}{c^3 d}+\frac {x^2 (a+b \arctan (c x))^2}{2 c^2 d}-\frac {i x^3 (a+b \arctan (c x))^2}{3 c d}+\frac {8 i b (a+b \arctan (c x)) \log \left (\frac {2}{1+i c x}\right )}{3 c^4 d}+\frac {(a+b \arctan (c x))^2 \log \left (\frac {2}{1+i c x}\right )}{c^4 d}+\frac {i b (a+b \arctan (c x)) \operatorname {PolyLog}\left (2,1-\frac {2}{1+i c x}\right )}{c^4 d}+\frac {b^2 \operatorname {PolyLog}\left (3,1-\frac {2}{1+i c x}\right )}{2 c^4 d}-\frac {\left (2 b^2\right ) \text {Subst}\left (\int \frac {\log (2 x)}{1-2 x} \, dx,x,\frac {1}{1+i c x}\right )}{3 c^4 d}-\frac {\left (2 i b^2\right ) \int \frac {\log \left (\frac {2}{1+i c x}\right )}{1+c^2 x^2} \, dx}{c^3 d}+\frac {b^2 \int \frac {x}{1+c^2 x^2} \, dx}{c^2 d} \\ & = -\frac {a b x}{c^3 d}-\frac {i b^2 x}{3 c^3 d}+\frac {i b^2 \arctan (c x)}{3 c^4 d}-\frac {b^2 x \arctan (c x)}{c^3 d}+\frac {i b x^2 (a+b \arctan (c x))}{3 c^2 d}-\frac {5 (a+b \arctan (c x))^2}{6 c^4 d}+\frac {i x (a+b \arctan (c x))^2}{c^3 d}+\frac {x^2 (a+b \arctan (c x))^2}{2 c^2 d}-\frac {i x^3 (a+b \arctan (c x))^2}{3 c d}+\frac {8 i b (a+b \arctan (c x)) \log \left (\frac {2}{1+i c x}\right )}{3 c^4 d}+\frac {(a+b \arctan (c x))^2 \log \left (\frac {2}{1+i c x}\right )}{c^4 d}+\frac {b^2 \log \left (1+c^2 x^2\right )}{2 c^4 d}-\frac {b^2 \operatorname {PolyLog}\left (2,1-\frac {2}{1+i c x}\right )}{3 c^4 d}+\frac {i b (a+b \arctan (c x)) \operatorname {PolyLog}\left (2,1-\frac {2}{1+i c x}\right )}{c^4 d}+\frac {b^2 \operatorname {PolyLog}\left (3,1-\frac {2}{1+i c x}\right )}{2 c^4 d}-\frac {\left (2 b^2\right ) \text {Subst}\left (\int \frac {\log (2 x)}{1-2 x} \, dx,x,\frac {1}{1+i c x}\right )}{c^4 d} \\ & = -\frac {a b x}{c^3 d}-\frac {i b^2 x}{3 c^3 d}+\frac {i b^2 \arctan (c x)}{3 c^4 d}-\frac {b^2 x \arctan (c x)}{c^3 d}+\frac {i b x^2 (a+b \arctan (c x))}{3 c^2 d}-\frac {5 (a+b \arctan (c x))^2}{6 c^4 d}+\frac {i x (a+b \arctan (c x))^2}{c^3 d}+\frac {x^2 (a+b \arctan (c x))^2}{2 c^2 d}-\frac {i x^3 (a+b \arctan (c x))^2}{3 c d}+\frac {8 i b (a+b \arctan (c x)) \log \left (\frac {2}{1+i c x}\right )}{3 c^4 d}+\frac {(a+b \arctan (c x))^2 \log \left (\frac {2}{1+i c x}\right )}{c^4 d}+\frac {b^2 \log \left (1+c^2 x^2\right )}{2 c^4 d}-\frac {4 b^2 \operatorname {PolyLog}\left (2,1-\frac {2}{1+i c x}\right )}{3 c^4 d}+\frac {i b (a+b \arctan (c x)) \operatorname {PolyLog}\left (2,1-\frac {2}{1+i c x}\right )}{c^4 d}+\frac {b^2 \operatorname {PolyLog}\left (3,1-\frac {2}{1+i c x}\right )}{2 c^4 d} \\ \end{align*}
Time = 1.03 (sec) , antiderivative size = 421, normalized size of antiderivative = 1.18 \[ \int \frac {x^3 (a+b \arctan (c x))^2}{d+i c d x} \, dx=\frac {i a^2 x}{c^3 d}+\frac {a^2 x^2}{2 c^2 d}-\frac {i a^2 x^3}{3 c d}-\frac {i a^2 \arctan (c x)}{c^4 d}-\frac {a^2 \log \left (1+c^2 x^2\right )}{2 c^4 d}-\frac {i a b \left (-3 i c x-8 c x \arctan (c x)+6 \arctan (c x)^2+\left (1+c^2 x^2\right ) (-1+3 i \arctan (c x)+2 c x \arctan (c x))+6 i \arctan (c x) \log \left (1+e^{2 i \arctan (c x)}\right )-8 \log \left (\frac {1}{\sqrt {1+c^2 x^2}}\right )+3 \operatorname {PolyLog}\left (2,-e^{2 i \arctan (c x)}\right )\right )}{3 c^4 d}-\frac {i b^2 \left (2 c x-6 i c x \arctan (c x)-2 \left (1+c^2 x^2\right ) \arctan (c x)+8 i \arctan (c x)^2-8 c x \arctan (c x)^2+3 i \left (1+c^2 x^2\right ) \arctan (c x)^2+2 c x \left (1+c^2 x^2\right ) \arctan (c x)^2+4 \arctan (c x)^3-16 \arctan (c x) \log \left (1+e^{2 i \arctan (c x)}\right )+6 i \arctan (c x)^2 \log \left (1+e^{2 i \arctan (c x)}\right )-6 i \log \left (\frac {1}{\sqrt {1+c^2 x^2}}\right )+(8 i+6 \arctan (c x)) \operatorname {PolyLog}\left (2,-e^{2 i \arctan (c x)}\right )+3 i \operatorname {PolyLog}\left (3,-e^{2 i \arctan (c x)}\right )\right )}{6 c^4 d} \]
[In]
[Out]
Result contains higher order function than in optimal. Order 9 vs. order 4.
Time = 47.77 (sec) , antiderivative size = 1105, normalized size of antiderivative = 3.10
method | result | size |
derivativedivides | \(\text {Expression too large to display}\) | \(1105\) |
default | \(\text {Expression too large to display}\) | \(1105\) |
parts | \(\text {Expression too large to display}\) | \(1149\) |
[In]
[Out]
\[ \int \frac {x^3 (a+b \arctan (c x))^2}{d+i c d x} \, dx=\int { \frac {{\left (b \arctan \left (c x\right ) + a\right )}^{2} x^{3}}{i \, c d x + d} \,d x } \]
[In]
[Out]
Timed out. \[ \int \frac {x^3 (a+b \arctan (c x))^2}{d+i c d x} \, dx=\text {Timed out} \]
[In]
[Out]
\[ \int \frac {x^3 (a+b \arctan (c x))^2}{d+i c d x} \, dx=\int { \frac {{\left (b \arctan \left (c x\right ) + a\right )}^{2} x^{3}}{i \, c d x + d} \,d x } \]
[In]
[Out]
\[ \int \frac {x^3 (a+b \arctan (c x))^2}{d+i c d x} \, dx=\int { \frac {{\left (b \arctan \left (c x\right ) + a\right )}^{2} x^{3}}{i \, c d x + d} \,d x } \]
[In]
[Out]
Timed out. \[ \int \frac {x^3 (a+b \arctan (c x))^2}{d+i c d x} \, dx=\int \frac {x^3\,{\left (a+b\,\mathrm {atan}\left (c\,x\right )\right )}^2}{d+c\,d\,x\,1{}\mathrm {i}} \,d x \]
[In]
[Out]